package day0309;

import java.util.Map;
import java.util.TreeMap;
import java.util.TreeSet;

public class Demo02 {


    public static void main(String[] args) {
//        Map map = Map.of(1, "a");
//        map.replace(1, "b"); // ex

        TreeMap map = new TreeMap();

        map.put(1, "a");
        map.put(1, "b");
        map.put(2, "b");
        map.put(3, null);

        System.out.println(map);

//        System.out.println(map.remove(3));
        System.out.println(map.remove(1, "b"));


        System.out.println(map);
    }
}
